CREATE TABLE [dbo].[Tb_Renuncias]
(
[idrenuncia] [int] NOT NULL IDENTITY(1, 1),
[agente] [int] NOT NULL,
[servicio] [int] NOT NULL,
[plazaLiberada] [int] NOT NULL,
[fecha] [datetime] NOT NULL,
[vacante] [int] NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[Tb_Renuncias] ADD CONSTRAINT [PK_Tb_Renuncias] PRIMARY KEY CLUSTERED  ([idrenuncia]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[Tb_Renuncias] WITH NOCHECK ADD CONSTRAINT [FK_Tb_Renuncias_tb_Agentes] FOREIGN KEY ([agente]) REFERENCES [dbo].[tb_Agentes] ([idAgente])
GO
ALTER TABLE [dbo].[Tb_Renuncias] WITH NOCHECK ADD CONSTRAINT [FK_Tb_Renuncias_tb_Plazas] FOREIGN KEY ([plazaLiberada]) REFERENCES [dbo].[tb_Plazas] ([idPlaza])
GO
ALTER TABLE [dbo].[Tb_Renuncias] WITH NOCHECK ADD CONSTRAINT [FK_Tb_Renuncias_tb_Vacantes] FOREIGN KEY ([vacante]) REFERENCES [dbo].[tb_Vacantes] ([idVacante])
GO
